//
//  HeaderOfEverySectionForClickCell.m
//  SeeTheWorld
//
//  Created by dllo on 16/1/25.
//  Copyright © 2016年 dllo. All rights reserved.
//

#import "HeaderOfEverySectionForClickCell.h"
#import "ModelOfTripDays.h"
#import "PCH.pch"
#import <UIImageView+WebCache.h>


@interface HeaderOfEverySectionForClickCell ()

@property (nonatomic, retain)UIView *viewForHeader;
@property (nonatomic, retain)UILabel *labelOfTime;

@end

@implementation HeaderOfEverySectionForClickCell

- (void)dealloc {
    [_labelOfTime release];
    [_viewForHeader release];
    [super dealloc];
}

- (instancetype)initWithReuseIdentifier:(NSString *)reuseIdentifier {
    
    self = [super initWithReuseIdentifier:reuseIdentifier];
    if (self) {
        
        
        [self createSubviews];
        
    }
    return self;
    
}

/** 创建子视图 */
- (void)createSubviews {
    
    self.viewForHeader = [[UIView alloc] init];
    [self.contentView addSubview:self.viewForHeader];
    self.viewForHeader.backgroundColor = [UIColor colorWithRed:224 / 256.f green:224 / 256.f blue:224 / 256.f alpha:0.4];
    [_viewForHeader release];
    
    self.labelOfTime = [[UILabel alloc] init];
    [self.contentView addSubview:self.labelOfTime];
    [_labelOfTime release];
    self.labelOfTime.dk_textColorPicker = DKColorWithRGB(0x343434, 0xffffff);

}

/** 布局子视图 */
- (void)layoutSubviews {
    [super layoutSubviews];
    self.viewForHeader.frame = self.contentView.frame;
    
    self.labelOfTime.frame = CGRectMake(20, 2, self.contentView.frame.size.width - 40, self.contentView.frame.size.height - 4);
    self.labelOfTime.textAlignment = NSTextAlignmentCenter;
}

/** 赋值 */
- (void)passModel:(NSString *)model {
    self.labelOfTime.text = model;
}




@end
